#ifndef TDLG_H
#define TDLG_H

#ifndef STRICT
#define STRICT
#endif
#include "twin.h"

class TDlg : public TWin {
protected:
	LPSTR	resName;
	UINT	resId;
	BOOL	modalFlg;

public:
	TDlg(LPSTR _name, TWin *_parent = NULL);
	TDlg(UINT	resid, TWin *_parent = NULL);
	virtual ~TDlg();

	virtual BOOL	Create(HINSTANCE hI = NULL);
	virtual	void	Destroy(void);
	virtual int		Exec(void);
	virtual void	EndDialog(int);
	UINT			ResId(void) { return resId; }

	virtual BOOL	EvCreate(LPARAM lParam);
	virtual BOOL	EvCommand(WORD wNotifyCode, WORD wID, LPARAM hwndCtl);
	virtual BOOL	EvSysCommand(WPARAM uCmdType, POINTS pos);
	virtual BOOL	EvQueryOpen(void);

	virtual	BOOL	PreProcMsg(MSG *msg);
	virtual LRESULT	WinProc(UINT uMsg, WPARAM wParam, LPARAM lParam);
};

#endif